<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script type="module">

    import axios from './模拟axios.js';


    let btnCancel;
    axios({
        url: 'http://shenxiaoxu.com:3000/scoreList',
        cancelToken : new axios.CancelToken((cancel)=>{btnCancel = cancel})
    }).then(value=>{
        console.log(value);
    })
    btnCancel()
    //调用即触发取消请求
</script>
</body>
</html>